<template>
  <div v-if="crud.props.searchToggle">
    <el-input v-model="query.orderSerial" placeholder="订单编号" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-input v-model="query.deviceSerial" placeholder="设备编号" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-select v-model="query.orderStatus" clearable size="small" placeholder="订单状态" class="filter-item" style="width: 200px" @change="crud.toQuery">
      <el-option v-for="item in dict.dict.status_order" :key="item.dictValue" :label="item.dictLabel" :value="item.dictValue" />
    </el-select>
    <el-select v-model="query.payStatus" clearable size="small" placeholder="支付状态" class="filter-item" style="width: 200px" @change="crud.toQuery">
      <el-option v-for="item in dict.dict.status_order_pay" :key="item.dictValue" :label="item.dictLabel" :value="item.dictValue" />
    </el-select>
    <el-input v-model="query.rentUserName" placeholder="租户名" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-input v-model="query.userPhone" placeholder="用户手机号" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-input v-model="query.hospitalName" placeholder="医院名称" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-input v-model="query.buildingName" placeholder="楼栋名称" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-input v-model="query.floorName" placeholder="楼层名称" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-input v-model="query.departName" placeholder="科室名称" style="width: 200px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <el-date-picker v-model="query.dateScope" type="datetimerange" format="yyyy-MM-dd HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" range-separator="至" start-placeholder="开始时间" end-placeholder="结束时间" style="width: 410px;" class="filter-item" @keyup.enter.native="crud.toQuery" />
    <!--通用查询-->
    <rrOperation :crud="crud" />
  </div>
</template>

<script>
import { header } from '@crud/crud'
import rrOperation from '@crud/RR.operation'

export default {
  components: { rrOperation },
  mixins: [header()],
  props: {
    dict: {
      type: Object,
      required: true
    },
    permission: {
      type: Object,
      required: true
    }
  }
}
</script>
